package com.example.a.dongtutest;

import android.content.Context;
import android.graphics.drawable.AnimationDrawable;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.view.animation.Animation;
import android.view.animation.AnimationUtils;
import android.widget.ImageView;

public class test3 extends AppCompatActivity {
    private Context mContext;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        mContext=getApplicationContext();
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_test3);
        ImageView image = (ImageView) findViewById(R.id.iv_1);

        Animation animation = AnimationUtils.loadAnimation(mContext, R.anim.alpha_anim);

        image.startAnimation(animation);

    }
}
